<?php
namespace CAI\HistoricoBundle\Controller;

use Symfony\Bundle\FrameworkBundle\Controller\Controller;
use Symfony\Component\HttpFoundation\Request;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\HttpFoundation\JsonResponse;
use CAI\HistoricoBundle\Entity\TorneoInstancia;
use CAI\HistoricoBundle\Entity\Torneo;
use CAI\HistoricoBundle\Form\Type\TorneoInstanciaType;
use CAI\HistoricoBundle\Form\Type\TorneoType;


class TorneosController extends Controller
{
	public function torneosAction(Request $request)
	{
		$torneoInstancia = new TorneoInstancia();
		$formTorneoInstancia = $this->createForm(new TorneoInstanciaType(), $torneoInstancia);
		
		$torneo = new Torneo();
		$formTorneo = $this->createForm(new TorneoType(), $torneo);
		
		return $this->render('CAIHistoricoBundle:Default:bootstrap.torneos.html.php', array('formTorneoInstancia' => $formTorneoInstancia->createView(), 'formTorneo' => $formTorneo->createView()));
	}
	
	
}